package com.lsw.jgyf.inject.modules;

import android.app.Activity;
import android.content.Context;

import com.lsw.jgyf.inject.scope.PerActivity;

import dagger.Module;
import dagger.Provides;

/**
 * author：lsw
 */
@Module
public class ActivityModule {
    private Activity mActivity;

    public ActivityModule(Activity mActivity) {
        this.mActivity = mActivity;
    }

    @PerActivity
    @Provides
    public Activity provideActivity() {
        return this.mActivity;
    }

    @Provides
    public Context provideContext(){
        return this.mActivity;
    }
}
